Loading provides the mechanism for dynamically loading executables (a.out format files) into the pcr.
To create the loading world, one just has to issue the command 'make' in the
loading subdirectory othe the DEVELOPMENT tree. This will cause loading.o to
be created and this is the component which will be bound into the pcr. In
addition to loading.o, the following commands are also created:
transform_symtab fixcore simplify_symtab delete_symtab and are inserted into the
/BIN subdirectory as commands available by the loading component. The man entry
for cedarload under pcr should be consulted for an explanation of these
commands.
The loading component will keep a record of each "a.out" file that has been loaded, along with the address at which it has been loaded. This record is kept in a file named /tmp/symtab.pidXXX where XXX is the process ID of the pcr. This file is later used by "transform_symtab" within "XrDBX" inorder to create an "a.out" file that DBX can read and use for debugging.
There are four regression tests (for now) that are of interest:
testload, testjmp, testsignaltrace, and testsignaljmp. Testload will create a
'loadable' world and to run this regression test, you should first type
'make testload', and then run testload and load into it test1, test2, test3
(in that order -- they will be created with 'make testload'). Then at
the prompt for testload, type 'call _test3' and the following should be printed:
Hello wolrd
inside test3
Inside test2
Hello world
Hello world
'_test3' returns 2b
The rest of the regression tests will run themselves when a make to them
is inferred.
Loading has one include file (unwind.h) that is exported to the rest of the pcr
world and used internally in loading.
The bottom of the main make file contains a dependency listing of the files
that make up loading.
NOTES
- Provides dynamic loading of modules into pcr.
- Some regression tests missing files or not working (obsolete?). Look